<nav class="nav-bar side-padding">
  <h1 class="nav-header"><a href="{{ .Site.BaseURL }}" class="nav-text">
    {{- if isset $.Site.Params "brand"}}
      {{- $.Site.Params.brand -}}
    {{ else }}
      {{- $.Site.Title -}}
    {{ end -}}
  </a></h1>
  <div class="hamburger-menu">
    <button onclick="hamburgerMenuPressed.call(this)" aria-haspopup="true" aria-expanded="false" aria-controls="menu" aria-label="Menu">
      <span></span>
      <span></span>
    </button>
    <ul id="menu" class="hamburger-menu-overlay">
      <li><a href="{{ .Site.BaseURL }}" class="hamburger-menu-overlay-link">Home</a></li>
      {{ range where .Site.Pages "Params.displayinmenu" true -}}
        <li><a href="{{ .Permalink }}" class="hamburger-menu-overlay-link">{{ .Title }}</a></li>
      {{ end -}}
      {{ range $key, $value := .Site.Taxonomies.categories -}}
      {{ with $.Site.GetPage (printf "%s%s" "categories/" ($key | urlize)) }}
      <li><a href="{{ .Permalink }}" class="hamburger-menu-overlay-link">{{ .Title }}</a></li>
      {{ end }}
      {{- end }}
      {{ if eq .Site.Params.rssinmenu true -}}
      <li><a href="{{ "/index.xml" | absURL }}" class="hamburger-menu-overlay-link">rss</a></li>
      {{- end }}
    </ul>
  </div>
</nav>
